package com.lb.jwitter;
import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import org.hibernate.annotations.ForeignKey;

@Entity
@Table (name="tbl_thongtin_hocvien")
public class Tbl_ThongTin_HocVien implements Serializable {
   private static final long serialVersionUID = -1989579066723007050L;

   private Long id;
   private String mSSV;
   private String hoTen;
   private String lopHoc;
   private Tbl_CTDT_ChuyenNganh chuyenNganhId = null;
   private Integer khoaHoc;
   private Integer namDauVao;
   private Tbl_CTDT_Khoa khoaId = null;
   private Tbl_CTDT_HeDaoTao heDaoTaoId = null;
   private String trangThai;
   private String email;

   @Id
   @GeneratedValue
   public Long getId() {
	    return id;
   }
   public void setId(Long id) {
	    this.id= id;
   }

   public String getMSSV() {
   	return mSSV;
   }
   public void setMSSV(String mSSV) {
   	this.mSSV= mSSV;
   }

   public String getHoTen() {
   	return hoTen;
   }
   public void setHoTen(String hoTen) {
   	this.hoTen= hoTen;
   }

   @ManyToOne(fetch=FetchType.EAGER)
   @JoinColumn(name="ChuyenNganhId")
   @ForeignKey(name="FK_tbl_CTDT_ChuyenNganh_tbl_ThongTin_HocVien")
   public Tbl_CTDT_ChuyenNganh getChuyenNganhId() {
	    return chuyenNganhId;
   }
   public void setChuyenNganhId(Tbl_CTDT_ChuyenNganh chuyenNganhId) {
	    this.chuyenNganhId=chuyenNganhId;
   }

   public Integer getKhoaHoc() {
   	return khoaHoc;
   }
   public void setKhoaHoc(Integer khoaHoc) {
   	this.khoaHoc= khoaHoc;
   }

   public Integer getNamDauVao() {
   	return namDauVao;
   }
   public void setNamDauVao(Integer namDauVao) {
   	this.namDauVao= namDauVao;
   }

   @ManyToOne(fetch=FetchType.EAGER)
   @JoinColumn(name="KhoaId")
   @ForeignKey(name="FK_tbl_CTDT_Khoa_tbl_ThongTin_HocVien")
   public Tbl_CTDT_Khoa getKhoaId() {
	    return khoaId;
   }
   public void setKhoaId(Tbl_CTDT_Khoa khoaId) {
	    this.khoaId=khoaId;
   }

   @ManyToOne(fetch=FetchType.EAGER)
   @JoinColumn(name="HeDaoTaoId")
   @ForeignKey(name="FK_tbl_CTDT_HeDaoTao_tbl_ThongTin_HocVien")
   public Tbl_CTDT_HeDaoTao getHeDaoTaoId() {
	    return heDaoTaoId;
   }
   public void setHeDaoTaoId(Tbl_CTDT_HeDaoTao heDaoTaoId) {
	    this.heDaoTaoId=heDaoTaoId;
   }

   public String getTrangThai() {
   	return trangThai;
   }
   public void setTrangThai(String trangThai) {
   	this.trangThai= trangThai;
   }
   
   public String getLopHoc() {
	   	return lopHoc;
	   }
	   public void setLopHoc(String lopHoc) {
	   	this.lopHoc= lopHoc;
	   }

   public String getEmail() {
   	return email;
   }
   public void setEmail(String email) {
   	this.email= email;
   }
}//endClass 

